!!!###!!!title=160-How to disable the default interactive behavior of legends——VisActor/VChart FAQ documents!!!###!!!

How to disable the default interactive behavior of legends?

Question Description

When displaying charts on the mobile end, in order to facilitate user reading, the legend size of the chart will be expanded. But almost every chart library's legend component defaults to setting default interactive behavior for the legend, such as filtering data when clicked.

How to cancel the default interaction of the legend in the chart, which is prone to accidentally touching it when sliding your fingers?

Solution

VChart provides interactive configurations for interactive marks or components to control whether interactive features are enabled or disabled, such as legends, chart annotations, various types of elements, etc. Although this configuration is enabled by default, users can control the interactive behavior of the chart themselves.

Code Example

Quote